<!Doctype html>
<html lang="en">
<head>
	<meta charset="UTF-8">
	<meta name="csrf-token" content="{{ csrf_token() }}">
	<meta name="viewport" content="width=device-width, initial-scale=1, maximum-scale=1, user-scalable=no">	
	<link rel="shortcut icon" type="image/x-icon" href="{{URL::asset('handan/images/logo-icon.png')}}" />
	<title>分析师认证</title>
	<link rel="stylesheet" href="{{URL::asset('mobile/css/public.css') }}"/>
	<link rel="stylesheet" href="{{URL::asset('mobile/css/analystcertify.css') }}"/>
	<script src="{{URL::asset('public_js/jquery-3.2.1.min.js')}}"></script>
	<script src="{{URL::asset('mobile/js/public.js') }}"></script>
	
</head>
<body>
	<!--审核中展示的信息  0::未认证 1:已提交认证信息 2:认证成功 3:认证失败-->
	<div class="fillin" id="fillin" style="display: @if($userinfo -> authstatus == '0') block @else none @endif">
		<section class="title">
			身份认证
		</section>
		<section class="name">
			<div>姓名</div>
			<div>
				<input type="text" placeholder="请输入姓名" id="fname" value="@if($authinfo){{$authinfo->username}}@endif" style="disabled:@if($userinfo -> authstatus == '2') disabled @else  @endif"/>
			</div>
		</section>
		<section class="idnum">
			<div>身份证号</div>
			<div>
				<input type="text" placeholder="请输入身份证号" id="fid" value="@if($authinfo){{$authinfo->idcard}}@endif" style="disabled:@if($userinfo -> authstatus == '2') disabled @else  @endif"/>
			</div>
		</section>
		<section class="title">
			上传身份证照片
		</section>
		<section class="pleaseup">
			请上传字迹清晰的照片
		</section>
		<section class="upload">
			<!-- 正面 -->
	        <div class="front" id="frontBox">
	            <input style="display: none;" name="idcardimg" id="idcardimg" type="text" value="@if($authinfo){{$authinfo->idcardimg}}@endif"/>
	            <img src="@if($authinfo) {{$authinfo->idcardimg}} @else {{URL::asset('mobile/image/analystcenter/front.png')}}@endif" alt="" id='img1' class="imgfront" />
	            <form id="uploadzhengForm" name="uploadzhengForm" action="{{url('uploadimg')}}" method="post">
	                <input style="display: none;" name="image" id="front_icon" type="file" class="inputFile" accept="image/*" capture="camera"/>
	                <input style="display: none;" name="type" type="text" value="2"/>
	            </form>
	        </div>
	        <!-- 反面 -->
	        <div class="back" id="backBox">
	            <input style="display: none;" name="idcardimgf" id="idcardimgf" type="text" value="@if($authinfo){{$authinfo->idcardimgf}}@endif"/>
	            <img src="@if($authinfo) {{$authinfo->idcardimgf}} @else {{URL::asset('mobile/image/analystcenter/back.png')}} @endif" alt="" id='img2' class="imgback" />
	            <form id="uploadfanForm" name="uploadfanForm" action="{{url('uploadimg')}}" method="post">
	                <input style="display: none;" name="image" id="back_icon" type="file" class="inputFile" accept="image/*" capture="camera"/>
	                <input style="display: none;" name="type" type="text" value="2"/>
	            </form>
	        </div>
		</section>
		<!--示例-->
		<section class="exp">
			<div><img src="{{url::asset('mobile/image/analystcenter/exp2.png')}}" alt="" /></div>
			<div><img src="{{url::asset('mobile/image/analystcenter/exp1.png')}}" alt="" /></div>
		</section>
		<section class="title">
			学历认证
		</section>
		<section class="sch">
			<div>学历</div>
			<div>
				<input type="text" placeholder="请输入学历" id="fedu" value=""/>
			</div>
			<div>毕业院校</div>
			<div>
				<input type="text" placeholder="请输入毕业院校" id="fschool" value=""/>
			</div>
		</section>
		<section class="confirm">
			<div onclick="confirm();">确认</div>
		</section>
	</div>
	<!--审核成功后展示-->
	<div class="fillin" id="fillin" style="display: @if($userinfo -> authstatus == '2') block @else none @endif">
		<section class="title">
			身份认证
		</section>
		<section class="name">
			<div>姓名</div>
			<div>
				<input type="text" placeholder="请输入姓名" id="fname" value="@if($authinfo){{$authinfo->username}}@endif" disabled="disabled" style="color: #81818b;"/>
			</div>
		</section>
		<section class="idnum">
			<div>身份证号</div>
			<div>
				<input type="text" placeholder="请输入身份证号" id="fid" value="@if($authinfo){{$authinfo->idcard}}@endif" disabled="disabled" style="color: #81818b;"/>
			</div>
		</section>
		<section class="title">
			学历认证
		</section>
		<section class="sch">
			<div>学历</div>
			<div>
				<input type="text" placeholder="请输入学历" id="fedu" value="@if($authinfo){{$authinfo->diplomas}}@endif"/>
			</div>
			<div>毕业院校</div>
			<div>
				<input type="text" placeholder="请输入毕业院校" id="fschool" value="@if($authinfo){{$authinfo->school}}@endif"/>
			</div>
		</section>
	</div>
	<!--填写第一次  审核中状态提示-->
	<section class="ingtip" id="ingtip" style=" display: @if($userinfo -> authstatus == '1') block @else none @endif">
		<div>
			<img src="{{ url::asset('mobile/image/analystcenter/success.png') }}" alt="" />
		</div>
		<p>您已成功提交信息</p>
		<p>正在等待审核</p>
		<div onclick="updateauth();">重新填写</div>
	</section>
	<!--填写后  审核失败状态提示-->
	<section class="errortip" id="errortip" style=" display: @if($userinfo -> authstatus == '3') block @else none @endif">
		<div>
			<img src="{{ url::asset('mobile/image/analystcenter/error.png') }}" alt="" />
		</div>
		<p>审核未通过,请重新填写</p>
		<div onclick="updateauth();">重新填写</div>
	</section>
@include('mobile.msg')
<script type="text/javascript">  
	var renzheng   = '{{url("/authenticate")}}';
	var imgurl     = "{{url('uploadimg')}}";//上传图片地址
	var cardauth   = "{{url('cardauth')}}"; //提交身份证地址
	var schoolurl  = '{{url("schoolauth")}}';//提交学历信息
</script>
<script src="{{URL::asset('mobile/js/analystcertify.js') }}"></script>